/*jshint esversion: 9 */
import { service } from './request';
import qs from 'qs';

/** 公用接口 */
const allApi = {
    login() {
        // return service({
        //     url:"/public/captcha",
        //     method:'get',
        // });
        return Promise.resolve({
            msg: '操作成功',
            code: 200,
            token: 'eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6ImJmMmYyMWRlLTUwNzctNDUxNy1hYmRlLTA0NGE4NzNhMzE0ZSJ9.DOnUxWppbtKyJGlvSBZqdExf5hrt0EdWalanz_op7rvyc9v-itJJZXbW0xn_yS5SZfXLYn1BRMlTdxadUmRmAg',
        });
    },
    getUserInfo() {
        return Promise.resolve({
            msg: '操作成功',
            code: 200,
            data: {
                userName: 'admin',
                nickName: '管理员',
                avatar: 'https://s11.ax1x.com/2023/12/15/pihx4js.jpg',
            },
        });
    },
    getMenuList() {
        let menuList = [
            // {
            //     name: 'show-list',
            //     title: '首页',
            //     content: '(有缓存，并且标签页固定)',
            //     isCache: true,
            //     fixed: true,
            //     iconName: 'svg:all-fill.svg',
            // },
            {
                name: 'new-tag-page',
                title: '新标签页',
                isCache: true,
                hidden: true,
            },
            {
                name: 'main-401',
                title: '401页面',
                isCache: true,
                hidden: true,
            },
            {
                name: 'main-404',
                title: '404页面',
                isCache: true,
                hidden: true,
            },

            {
                name: 'show-list',
                title: '驾驶舱',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-3',
                title: '日前-日内发电计划',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-1',
                title: '系统级AGC/AVC',
                iconName: 'svg:laptop-check.svg',

            },


            {
                name: 'show-list-4',
                title: '风电场模块',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-5',
                title: '光伏电站模块',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-6',
                title: '光热电站模块',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-7',
                title: '电加热器模块',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-8',
                title: '电化学储能',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-9',
                title: '系统无功模块',
                iconName: 'svg:laptop-check.svg',

            },
            {
                name: 'show-list-10',
                title: '历史数据',
                iconName: 'svg:laptop-check.svg',

            },




        ];
        return Promise.resolve({
            msg: '操作成功',
            code: 200,
            data: menuList,
        });
    },
};

export default allApi;
